package cn.maxwell.service.impl;

import cn.maxwell.domain.Product;
import cn.maxwell.mapper.ProductMapper;
import cn.maxwell.service.IProductService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class ProductServiceImpl implements IProductService {

    @Resource
    private ProductMapper productMapper;

    @Override
    public List<Product> loadAll() {
        return null;
    }

    @Override
    public Product loadById(Long id) {
        return productMapper.loadById(id);
    }

    @Override
    public void delete(Long id) {
        productMapper.delete(id);
    }

    @Override
    public void add(Product Product) {
        productMapper.add(Product);
    }

    @Override
    public void update(Product Product) {
        productMapper.update(Product);
    }
}
